package chapter3.No3_1_等待和通知机制.d方法wait锁释放与notify锁不释放.demo2;

/**
 * *：验证notify方法执行的时候，不会立刻释放锁，而是要等待同步执行完成后才释放
 * Created by Administrator on 2016/11/17.
 */
public class Main {
    public static void main(String[] args) {
        Object lock = new Object();
        ThreadA a = new ThreadA(lock);
        a.setName("aa");
        ThreadA b = new ThreadA(lock);
        b.setName("bb");

        a.start();
        b.start();

    }
}
